#!/bin/bash

# sysctl -w net.ipv4.ip_forward=1
# echo 1 > /proc/sys/net/ipv4/ip_forward 
# sleep 3

nohup /usr/sbin/pppd call OSLO_VPN >/dev/null 2>&1 &
sleep 5

route add -net 10.0.0.0 netmask 255.0.0.0 gw 10.101.0.167 device ppp0
[ $? -eq 0 ] && echo "Connected."

#mv /etc/resolv.conf /etc/resolv.conf.oslo.bck
#cat /etc/resolv.conf.oslo.bck | awk 'BEGIN{print "nameserver 10.0.0.1"}{ print $0; }' > /etc/resolv.conf

